﻿<%@ Page Title="" Language="VB" MasterPageFile="~/Administrator/MasterPage.master"
    AutoEventWireup="false" CodeFile="mSanctionList.aspx.vb" Inherits="Administrator_mSanctionList" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <script src="../Scripts/JScript.js" type="text/javascript"></script>
    <script type="text/javascript">
        var hasSubmitted = 0;
        function NoDoubleSubmit() {
            var divMsg = document.getElementById('Processing');
            if (hasSubmitted == 0) {
                hasSubmitted = 0;
                divMsg.style.display = 'block';
                return true;
            }
            return false;
        }

        function NoDoubleSave() {
            var divMsg = document.getElementById('Saving');
            if (hasSubmitted == 0) {
                hasSubmitted = 0;
                divMsg.style.display = 'block';
                return true;
            }
            return false;
        }

    </script>
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
            <table style="width: 100%;">
                <tr>
                    <td align="right">
                        <asp:Label ID="lblListTypeCode" runat="server" CssClass="control">ชื่อลิสต์ความเสี่ยง :</asp:Label>
                    </td>
                    <td align="left" style="height: 26px">
                        <asp:TextBox ID="txtListTypeCode" runat="server" CssClass="control" Height="20px"
                            Width="188px" AutoCompleteType="Disabled" MaxLength="20"></asp:TextBox>
                    </td>
                    <td align="left" style="height: 26px; text-align: right;">
                        <asp:Label ID="lblListTypeName" runat="server" CssClass="control">รายละเอียดลิสต์ :</asp:Label>
                    </td>
                    <td align="left" style="height: 26px">
                        <asp:TextBox ID="txtListTypeName" runat="server" AutoCompleteType="Disabled" CssClass="control"
                            Height="20px" MaxLength="100" Width="343px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td align="right" valign="top">
                        <asp:Label ID="lblFileName" runat="server" CssClass="control">ชื่อไฟล์ :</asp:Label>
                    </td>
                    <td align="left" valign="top">
                        <asp:TextBox ID="txtFileName" runat="server" AutoCompleteType="Disabled" CssClass="control"
                            Height="20px" MaxLength="100" Width="187px"></asp:TextBox>
                    </td>
                    <td align="left" style="text-align: right" valign="top">
                        <asp:Label ID="lblRiskLevel" runat="server" CssClass="control">ระดับความเสี่ยง :</asp:Label>
                    </td>
                    <td align="left" style="width: 333px">
                        <asp:TextBox ID="txtRiskLevel" runat="server" AutoCompleteType="Disabled" CssClass="control"
                            Height="20px" MaxLength="3" Width="69px" onkeypress="javascript:return NumberOnly(event);"
                            onchange="Max_KeyNum(this.id, 100)"></asp:TextBox>
                        <br />
                    </td>
                </tr>
                <tr>
                    <td align="right" valign="top">
                        <asp:Label ID="lblBatchJob" runat="server" CssClass="control">ชื่อไฟล์ Batch :</asp:Label>
                    </td>
                    <td align="left" valign="top">
                        <asp:TextBox ID="txtBatchJob" runat="server" AutoCompleteType="Disabled" CssClass="control"
                            Height="20px" MaxLength="100" Width="226px"></asp:TextBox>
                    </td>
                    <td align="left" style="text-align: right" valign="top">
                        <asp:Label ID="lblBatchTestJob" runat="server" CssClass="control">ชื่อไฟล์ Batch Test :</asp:Label>
                    </td>
                    <td align="left" style="width: 333px">
                        <asp:TextBox ID="txtBatchTestJob" runat="server" AutoCompleteType="Disabled" CssClass="control"
                            Height="20px" MaxLength="100" Width="226px"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td align="right">
                        &nbsp;
                    </td>
                    <td align="left" style="text-align: right">
                        &nbsp;
                    </td>
                    <td align="left" style="text-align: right;" colspan="2">
                        <asp:Button ID="btnSearch" runat="server" CssClass="control" Text="search" Width="80px" />
                        <asp:Button ID="btnAdd" runat="server" CssClass="control" Text="Add" Width="80px" />
                        <asp:Button ID="btnModify" runat="server" CssClass="control" Text="Modify" Width="80px" />
                        <asp:Button ID="btnDelete" runat="server" CssClass="control" Text="Delete" Width="80px" />
                        <asp:Button ID="btnClear" runat="server" CssClass="control" Text="Clear" Width="80px" />
                        <asp:Button ID="btnPrint" runat="server" CssClass="control" Text="Print" Width="80px"
                            Visible="False" />
                    </td>
                </tr>
                <tr>
                    <td colspan="4">
                        <asp:Label ID="Label1" runat="server" CssClass="control" Font-Bold="True" ForeColor="Red"
                            Text="ไม่พบข้อมูล" Visible="False" Font-Size="X-Large" Height="30px"></asp:Label>
                        <span id="Processing" style="display: none">
                            <img src="../img/icon/ajax-loader.gif" alt="Please wait" />
                            กรุณารอสักครู่ ระบบกำลังค้นหาข้อมูล... </span>
                        <span id="Saving" style="display: none">
                            <img src="../img/icon/ajax-loader.gif" alt="Please wait" />
                            กรุณารอสักครู่ ระบบกำลังบันทึกข้อมูล... </span>
                    </td>
                </tr>
            </table>
            <div align="center">
                <asp:Label ID="lblMsg" runat="server" CssClass="control" Font-Size="X-Large" ForeColor="Red"
                    Height="30px" Style="text-align: center" Font-Bold="True"></asp:Label>
                <asp:GridView ID="gvSanctionList" runat="server" AllowSorting="True" AutoGenerateColumns="False"
                    CellPadding="4" CssClass="control" ForeColor="#333333" Width="100%" AllowPaging="True">
                    <RowStyle BackColor="#FFFBD6" ForeColor="#333333" />
                    <FooterStyle BackColor="White" Font-Bold="True" ForeColor="#333333" />
                    <RowStyle ForeColor="#333333" />
                    <PagerSettings Mode="NumericFirstLast" />
                    <PagerStyle BackColor="#FFCC66" ForeColor="#333333" HorizontalAlign="Center" CssClass="cssPager" />
                    <SelectedRowStyle BackColor="#FFFFCC" Font-Bold="True" ForeColor="Navy" />
                    <HeaderStyle BackColor="#E38120" Font-Bold="True" ForeColor="White" />
                    <AlternatingRowStyle BackColor="White" />
                    <Columns>
                        <asp:CommandField ButtonType="Image" SelectImageUrl="~/img/icon/select_icon.gif"
                            ShowSelectButton="True">
                            <ItemStyle Width="3%" />
                        </asp:CommandField>
                        <asp:BoundField DataField="ListTypeCode" HeaderText="ชื่อลิสต์ความเสี่ยง" ReadOnly="True"
                            SortExpression="ListTypeCode">
                            <ItemStyle HorizontalAlign="Left" Width="130px" />
                        </asp:BoundField>
                        <asp:BoundField DataField="ListTypeName" HeaderText="รายละเอียดลิสต์" ReadOnly="True"
                            SortExpression="ListTypeName">
                            <ItemStyle HorizontalAlign="Left" Width="180px" />
                        </asp:BoundField>
                        <asp:BoundField DataField="RiskLevel" HeaderText="ระดับความเสี่ยง">
                            <ItemStyle Width="120px" />
                        </asp:BoundField>
                        <asp:BoundField DataField="FileName" HeaderText="ชื่อไฟล์">
                            <ItemStyle HorizontalAlign="Left" Width="150px" />
                        </asp:BoundField>
                        <asp:BoundField DataField="BatchJob" HeaderText="ชื่อไฟล์ Batch">
                            <ItemStyle HorizontalAlign="Left" />
                        </asp:BoundField>
                        <asp:BoundField DataField="BatchTestJob" HeaderText="ชื่อไฟล์ Batch Test">
                            <ItemStyle HorizontalAlign="Left" />
                        </asp:BoundField>
                    </Columns>
                </asp:GridView>
            </div>
            <div align="right">
                <asp:Label ID="lblTotal" runat="server" Font-Bold="True" ForeColor="#003300"></asp:Label>
            </div>
        </ContentTemplate>
    </asp:UpdatePanel>
</asp:Content>
